package com.liu.eduService.controller;


import com.liu.R;
import com.liu.eduService.service.EduCourseDescriptionService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.DeleteMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;

import org.springframework.web.bind.annotation.RestController;

/**
 * <p>
 * 课程简介 前端控制器
 * </p>
 *
 * @author LSJ
 * @since 2022-01-07
 */
@RestController
@RequestMapping("/eduService/description")
public class EduCourseDescriptionController {
    @Autowired
    private EduCourseDescriptionService service;

    @DeleteMapping("{courseId}")
    public R deleteDescriptionBycourseId(@PathVariable String courseId){
        boolean delete = service.deleteDescriptionBycourseId(courseId);
        return delete?R.ok(): R.error();
    }

}

